<template>
  <div id="app">
    <div id="nav" v-for="(page, index) in pages" v-bind:key="index">
      <a @click="goFn('')">{{index + 1}}</a> |
      <a @click="goFn(page)">{{ page }}</a>
    </div>
  </div>
</template>

<script>
  export default {
    methods: {
      goFn(name, query = '') {
        this.$openRouter({
          name: name,
          query: query
        })
      }
    },
    data()  {
      return {
        //  'login', 'register', 'bankCard', 'message', 'home', 'memberOrder','memberCard',
      pages:[
        'myComments', 'myComplains', 'memberOrder', 'home', 'bankCard', 'login', 'registerNew',
      'goodsDetail', 'userRelation','address', 'rewardRecord',
      'message', 'personalCenter', 'comment', 'complain',
      ],
      }
    },
  }
</script>
<style lang="less" scoped>
#app {
  font-family: 'Avenir', Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
}
#nav {
  padding: 30px;
  a {
    font-weight: bold;
    color: #2c3e50;
    &.router-link-exact-active {
      color: #42b983;
    }
  }
}
</style>